<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <canvas id="canvas" width="1024" height="1024"></canvas>
  </body>
  <script>
    window.onload = function () {
      var canvas = document.querySelector("#canvas");
      var ctx = canvas.getContext("2d");
      ctx.font = "50px 宋体";
      ctx.strokeStyle = "pink";
      ctx.strokeText("JAY", 100, 100);
    };
  </script>
</html>
